package com.data.modules.smzh.service;

import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.data.common.api.vo.Result;
import com.data.modules.smzh.entity.Building;
import com.data.modules.smzh.entity.Facedevice;
import com.data.modules.smzh.entity.VisitorInfo;
import com.data.modules.smzh.vo.SmContactVo;
import com.data.modules.smzh.vo.SmDeviceVo;
import com.data.modules.system.entity.User;

import javax.servlet.http.HttpServletRequest;
import java.util.List;
import java.util.Map;

/**
 * @Description: facedevice
 * @Author: data-boot
 * @Date:   2022-11-29
 * @Version: V1.0
 */
public interface IFacedeviceService extends IService<Facedevice> {

    Boolean addBindDevice(SmDeviceVo smDeviceVo);

    void updateBindDeviceInfo(SmDeviceVo smDeviceVo);

    List<Map> getDeviceByUserId(Integer userId);

    String getDoorPassword(String userid);

   // int modifyOpenDoorPassword(User user, String userid);

    int modifyOpenDoorPassword(String userid, String newOpenDoorPassword, String serNo);

    List<Map> getPersonFace(String userid);

    int delAppFace(String id, String serialNo);

    int addAppFace(User user);

    int addInviteVisitors(VisitorInfo user);

    IPage<Facedevice> pageList(Page<Facedevice> page, Facedevice facedevice);

    Facedevice queryDeviceInfo(String serialNo, Integer type);

    List<SmDeviceVo> seachManageBaseInfo(SmDeviceVo smDeviceVo);

    Result doBindDevice(SmDeviceVo smDeviceVo, HttpServletRequest req);

    Result searchAllDevice(SmDeviceVo smDeviceVo, HttpServletRequest req);

    String queryDevelAppIdByToken(String token);

    String queryDevelAccountMobileByAppID(String appId);

    void synMsgBySn(String sn);

    void sendMqttMsg();

    void queryMqttStatus();

    String sendQrCode(VisitorInfo user,String mobile,List<String> doorList);

    String queryMobile(String userId);

    List<SmDeviceVo> queryDeviceList(String mobile);

    List<String> queryAppRegistId(String uniqueNo);
}
